package hu;

import java.util.*;

public class hu57 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        char[] ch1 = sc.nextLine().toCharArray();
        char[] ch2 = sc.nextLine().toCharArray();
        String ans = "";
        int f = 0;
        int len1 = ch1.length, len2 = ch2.length;
        if(len1 > len2){
            while(len2 > 0){
                int p = ch1[--len1] - '0' + ch2[--len2 ] - '0' + f;
                f = 0;
                if(p >= 10)
                    f = 1;
                ans += p % 10;
            }
            while(len1 > 0){
                int p = ch1[--len1] - '0' + f;
                f = 0;
                if(p >= 10)
                    f = 1;
                ans += p % 10;
            }
        }
        else{
            while(len1 > 0){
                int p = ch1[--len1] - '0' + ch2[--len2 ] - '0' + f;
                f = 0;
                if(p >= 10)
                    f = 1;
                ans += p % 10;
            }
            while(len2 > 0){
                int p = ch2[--len2] - '0' + f;
                f = 0;
                if(p >= 10)
                    f = 1;
                ans += p % 10;
            }
        }
        if(f == 1)
            ans += f;
        for (int i = ans.length() - 1; i >= 0; i--) {
            System.out.print(ans.charAt(i));
        }
    }
}
